<template>
	<view class="buyMain">
		<view v-html="content"></view>
	</view>
</template>

<script>
	export default {
		data() {
			return {
				content: ''
			}
		},
		methods: {
			loadData() {
				const $this = this
				uni.showLoading({
					title: 'loading...'
				})
				this._get('index/policy', {}, function(res) {

					uni.hideLoading()
					const {
						code,
						data
					} = res
					if (code === 1) {
						
						$this.content = data.needred
						$this.content = $this.content.replace(/<img/g,"<img style='max-width:100%;height:auto;'");
					}
				});
			}
		},
		created() {
			this.loadData()
		}
	}
</script>

<style scoped>
	.buyMain {
		overflow-x: hidden;
		width: 90%;
		background: #fff;
		margin: 10rpx auto;
		padding: 20rpx;

	}
</style>